import request from '@/utils/request'

// 创建图斑和流程实例关联
export function createTbProcess(data) {
  return request({
    url: '/bpm/tb-process/create',
    method: 'post',
    data: data
  })
} 

// 创建图斑和流程实例关联
export function createMutiTbProcess(data) {
  return request({
    url: '/bpm/tb-process/createMuti',
    method: 'post',
    data: data
  })
}

// 更新图斑和流程实例关联
export function updateTbProcess(data) {
  return request({
    url: '/bpm/tb-process/update',
    method: 'put',
    data: data
  })
}

// 删除图斑和流程实例关联
export function deleteTbProcess(id) {
  return request({
    url: '/bpm/tb-process/delete?id=' + id,
    method: 'delete'
  })
}

// 获得图斑和流程实例关联
export function getTbProcess(id) {
  return request({
    url: '/bpm/tb-process/get?id=' + id,
    method: 'get'
  })
}

// 获得图斑和流程实例关联分页
export function getTbProcessPage(query) {
  return request({
    url: '/bpm/tb-process/page',
    method: 'get',
    params: query
  })
}

// 导出图斑和流程实例关联 Excel
export function exportTbProcessExcel(query) {
  return request({
    url: '/bpm/tb-process/export-excel',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}
